# -*- coding:UTF-8 -*-
import time
import urllib
from urllib import request


def heart_beats():
    while True:
        url = "http://mockbin.com/request?foo=bar&foo=baz"
        request = urllib.request.Request(url)
        response = urllib.request.urlopen(request)
        content_b = response.read()
        content = content_b.decode('utf-8')
        print(content)
        time.sleep(10)


if __name__ == '__main__':
    heart_beats()
